<?php $this->headLink()->appendStylesheet('/modules/comments/css/style.css'); ?>

<div id="comments">
    <?php if ($this->paginator) : ?>
        <?php echo $this->paginationControl($this->paginator, 'Sliding', 'pagination.phtml'); ?>
    <?php endif; ?>
    <ul class="commentlist">
        <?php echo $this->partial('template/' . $this->template . '.phtml', 'comments', array('paginator' => $this->paginator, 'user' => $this->user)) ?>
    </ul>
    <?php if ($this->paginator) : ?>
        <?php echo $this->paginationControl($this->paginator, 'Sliding', 'pagination.phtml'); ?>
    <?php endif; ?>
    <ul class="commentlist">
        <?php if ($this->user):?>
            <li>
                <a href="#" class="thumbnail pull-left">
                <?php if ($this->user->avatar):?>
                    <img src="<?php echo $this->baseUrl($this->user->avatar)?>" alt="<?php echo $this->__('Avatar for')?> <?php echo $this->user->login?>" class="avatar"/>
                <?php else: ?>
                    <?php echo $this->gravatar($this->user->email, array(), array('title' => $this->__('Avatar for') . ' '  . $this->user->getName(), 'class' => 'avatar')) ?>
                <?php endif?>
                </a>
                <article class="comment">
                    <?php echo $this->form;?>
                </article>
            </li>
        <?php endif;?>
    </ul>
</div>